package com.education.db.domain;

import javax.persistence.*;

/**
 * Created by Fan on 2016/9/26.
 */
@Entity
@Table(name = "info_school", schema = "db_education", catalog = "")
public class InfoSchool {
    private int scId;
    private String scValue;
    private String scName;

    @Id
    @Column(name = "sc_id")
    public int getScId() {
        return scId;
    }

    public void setScId(int scId) {
        this.scId = scId;
    }

    @Basic
    @Column(name = "sc_value")
    public String getScValue() {
        return scValue;
    }

    public void setScValue(String scValue) {
        this.scValue = scValue;
    }

    @Basic
    @Column(name = "sc_name")
    public String getScName() {
        return scName;
    }

    public void setScName(String scName) {
        this.scName = scName;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        InfoSchool that = (InfoSchool) o;

        if (scId != that.scId) return false;
        if (scValue != null ? !scValue.equals(that.scValue) : that.scValue != null) return false;
        if (scName != null ? !scName.equals(that.scName) : that.scName != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = scId;
        result = 31 * result + (scValue != null ? scValue.hashCode() : 0);
        result = 31 * result + (scName != null ? scName.hashCode() : 0);
        return result;
    }
}
